//
//  StrategyInlandParser.m
//  ITrip
//
//  Created by dllo on 15/5/23.
//  Copyright (c) 2015年 lanou3g.com 蓝鸥科技. All rights reserved.
//

#import "StrategyInlandParser.h"

@implementation StrategyInlandParser

+ (NSMutableArray *)getInlandParser:(NSData *)data
{
    NSMutableArray *arrayData = [NSMutableArray array];
    NSArray *array = [NSJSONSerialization JSONObjectWithData:data options:NSJSONReadingMutableContainers error:nil];
    for (NSDictionary *dic in array) {
        if ([[dic objectForKey:@"category"] integerValue] == 99 || [[dic objectForKey:@"category"] integerValue] == 999) {
            
            NSArray *array1 = [dic objectForKey:@"destinations"];
            for (NSDictionary *dic1 in array1) {
                StrategyInlandModel *modelInland = [StrategyInlandModel getInlandModel];
                
                modelInland.name_zh_cn_Inland = [dic1 objectForKey:@"name_zh_cn"];
                modelInland.name_en_Inland = [dic1 objectForKey:@"name_en"];
                modelInland.poi_count_Inland = [[dic1 objectForKey:@"poi_count"]integerValue];
                modelInland.imageInland = [dic1 objectForKey:@"image_url"];
                [arrayData addObject:modelInland];
            }
        }
        
    }
    return arrayData;
}




@end
